Hi all,
void fnSelectSrcAttr(DBE calledfrom, int i){
int iCount
bool isCheck=getCheck(calledfrom,i)
print sizeof(srcAttributes) " "
print i "\n"
if (isCheck) {
for (iCount=0;iCount<=sizeof(srcAttributes)-2;iCount++){
if (iCount!=i){
setCheck(srcModAttrList,iCount,false)
}
}
}
}
print sizeof(srcAttributes) " "
returns 0 before crashing. SystemAdmin - Fri Oct 19 11:19:12 EDT 2012 |
Re: DBE listView callback being called recurrently
Well when you modify the DBE element inside its own 'on-change' callback you need to introduce a global variable to avoid an endless loop:
bool bInFunction = false
void myCallback (DBE) {
if (bInFunction == true) return // avoid endless loop
bInFunction = true
// ... modify element here ...
bInFunction = false
}
Mathias Mamsch, IT-QBase GmbH, Consultant for Requirement Engineering and D00RS
|
Re: DBE listView callback being called recurrently A semaphore scheme, as you proposed, solved the problem. |